import router from '../../router';
export default function install(Vue) {
  Vue.prototype.toPage = function(id, name = '新闻详情') {
    //到普通详情
    router.push({
      name: 'newsDetails',
      query: {
        id,
        name,
      },
    });
  };
  Vue.prototype.toPeople = function(id) {
    console.log(id);
    //到参赛人详情/这两个详情不一样
    router.push({
      name: 'People',
      query: {
        id,
      },
    });
  };
}
